package com.xja.git.service.impl;

import com.xja.git.entity.Gituser;
import com.xja.git.mapper.GituserMapper;
import com.xja.git.service.GitUserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @CreateTime
 * @Author:樊浩杰
 * @Description:
 */
@Service
public class GitUserServiceImpl implements GitUserService {
    @Autowired
    private GituserMapper gituserMapper;
    /**
     * 此方法是查询的方法
     */
    @Override
    public List<Gituser> selectAll() {
       return gituserMapper.selectAll();
    }

    /**
     * 删除
     * @param id
     * @return
     */
    @Override
    public int remove(Integer id) {
        return gituserMapper.deleteByPrimaryKey(id);
    }

    @Override
    public int addGituser(Gituser gituser) {
        return gituserMapper.insertSelective(gituser);
    }


}
